<div class='fui-page fui-page-current'>
    <div class="fui-header">
		<div class="fui-header-left">
			<a class="back" ng-click="goback()"></a>
		</div>
		<div class="title">余额充值</div> 
		<div class="fui-header-right">&nbsp;</div>
    </div>
    <div class="fui-content">
		<div class='fui-cell-group'>
			<div class="fui-cell">
			<div class="fui-cell-text">
						<div class="bold"><i class="icon icon-bussinesscard" style="color:#f60"></i> 线上会员卡</div>
						<div class="gray" style="font-size:0.55rem">卡内余额￥{{pagedata.item.credit2}}，可用￥{{pagedata.item.credit2}}</div>
					</div>
			</div>
			<div class="fui-cell-title syscolor" style="padding-bottom:0">任选一款，总有一款适合您！</div>
			<div class="fui-icon-group noborder col-3" style="padding:0.3rem">
					<div ng-repeat="item in pagedata.pluginset.conglist" ng-click="pagedata.post.money=item.fee;pagedata.post.songfee=item.songfee;pagedata.recharge()" class="fui-icon-col-sm" style="margin:0;padding:0 0.2rem">
							<div ng-class="{'btn btn-success-o':1,'active':pagedata.post.money==item.fee}" style="border-radius:0.2rem;line-height:1.4;margin:0;padding:1rem 0.3rem;width:100%">
							<div class="bold">充{{item.fee}}送{{item.songfee}}</div>
							</div>
					</div>
			</div>
			<div class='fui-cell'>
				<div class='fui-cell-label'>充值余额</div>
				<div class="fui-cell-info c000" style="display: -webkit-box;display: -webkit-flex;display: -ms-flexbox;display: flex;-webkit-box-align: center;-webkit-align-items: center;-ms-flex-align: center;align-items: center;">￥ <input class='fui-input' placeholder="输入充值金额" id='money' ng-model="pagedata.post.money"></div>
			</div>
		</div>
		<a href="javascript:;" class='btn btn-success block' style="line-height: 2.6;" ng-click="pagedata.recharge()">确认充值</a>
</div>
<script>
scope.pagedata.recharge=function(){
	scope.post_json('recharge',scope.pagedata.post,function(pay_id){
		console.log('pay_id');console.log(pay_id);
		var success_url='jy_merch/member.index/';
		scope.tool.pay(pay_id,function(res){
				console.log('收到支付结果！');
				if(res.type=='success'){
					scope.message('充值成功！','','goback');
				}else{
					scope.message('充值失败！'+res.message,'','goback');
				}
		},'','',success_url,success_url);
	});
}
</script>